package com.itheima.service.impl;

import com.itheima.dao.BookDao;
import com.itheima.service.BookService;
import lombok.Setter;

//注入: BookServiceImpl中注入BookDao接口的实现类
public class BookServiceImpl implements BookService {
    //private BookDao bookDao = new BookDaoImpl();    //紧耦合
    @Setter
    private BookDao bookDao;

    public void save() {
        System.out.println("book service save ...");
        bookDao.save();
    }

    /*public BookDao getBookDao() {
        return bookDao;
    }*/
}
